<?php

namespace App\Http\Controllers\Admin;

use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use App\Admin\Protype;

use Input;


class ProtypeController extends Controller
{
    //显示
    public function index(){
    	// 获取数据
    	$data = Protype::orderBy('sort','desc') -> get();
    	// 展示视图
    	return view('admin.protype.index',compact('data'));
    }

    // 添加
    public function add(){
    	if(Input::method() == 'POST'){
            $data = Input::get();
            var_dump($data);
    	}else{

    		return view('admin.protype.add');
    	}
    }
}
